package cycling.taxi.com.utils;

import android.content.Context;
import android.os.Handler;

/**
 * Created by hz on 2016/9/3.
 */
public class UiUtil {


    private static Context sContext; //静态的成员变量
    private static Handler sHandler;


    public static void postTask(Runnable task){
        sHandler.post(task);
    }



    //抽取获得Context的方法 ,给其他类提供context
    public static Context getContext() {
        return sContext;
    }

    public static void init(Context context) {
        sContext = context;

        sHandler = new Handler();


    }
}
